#include<bits/stdc++.h>
using namespace std;
const int MOD = 1e9+7;
const int N = 1e5+10;
int n,m,k;
long long id(int x,int y){
    return x*(m + 1) + y;
}
int main(){
    cin>>n>>m>>k;
    int tot = 0;
    for(int i = 1;i<=min(n,m);i++){
        tot = (tot + 1ll*(n - i + 1)*(m - i + 1)%MOD)%MOD;
    }
    vector<pair<int,int>> pai;
    unordered_set<long long> points;
    for(int i = 1;i<=k;i++){
        int x,y;
        cin>>x>>y;
        pai.push_back(make_pair(x,y));
        points.insert(id(x,y));
    }
    int cnt1 = 0;
    for(pair<int,int> p : pai){
        int up = p.second,down = m - p.second,left = p.first,right = n - p.first;
        cnt1 = (cnt1 + min(up,left) + min(up,right) + min(down,left) + min(down,right))%MOD;
    }
    int cnt2 = 0;
    int cnt3 = 0;
    int cnt4 = 0;
    for(int i = 0;i < pai.size();i++){
        for(int j = 0;j < i;j++){
            if(pai[i].first == pai[j].first){
                int len = abs(pai[i].second - pai[j].second);
                if(pai[i].first + len <= n){
                    cnt2++;
                }
                if(pai[i].first - len >= 0)
                {
                    cnt2++;
                }
            }else if(pai[i].second == pai[j].second){
                int len = abs(pai[i].first - pai[j].first);
                if(pai[i].second + len <= m){
                    cnt2++;
                }
                if(pai[i].second - len >= 0){
                    cnt2++;
                }
            }else{
                cnt2++;
                bool f1 = points.find(id(pai[i].first,pai[j].second)) != points.end();
                if(f1){
                    cnt3++;
                }
                bool f2 = points.find(id(pai[j].first,pai[i].second)) != points.end(); 
                if(f2){
                    cnt3++;
                }
                if(f1 && f2){
                    cnt4++;
                }
            }
        }
    }
    cnt4/=2;
    //cerr<<tot<<' '<<cnt1<<' '<<cnt2<<' '<<cnt3<<' '<<cnt4<<'\n';
    int ans = ((1ll*tot - cnt1 + cnt2 - cnt3 + cnt4)%MOD + MOD)%MOD;
    cout<<ans<<'\n';
}
/*
2 2 4 
1 0 
1 2 
0 1 
2 1
*/